package com.futureCloudMOM.core.domain;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.futureCloudMOM.core.entity.FBaseEntity;
import com.futureCloudMOM.framework.dict.Dict;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.io.Serializable;

@Data
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "Basic_Supplier", description = "供应商表")
@TableName(value = "Basic_Supplier")
public class BasicSupplier extends FBaseEntity implements Serializable {



    @NotBlank(message="[供应商编码]不能为空")
    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("供应商编码")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "code")
    private String code;

    @NotBlank(message="[供应商名称]不能为空")
    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("供应商名称")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "name")
    private String name;

    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("供应商地址")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "address")
    private String address;

    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("供应商联系人")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "contact")
    private String contact;

    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("供应商电话")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "phone")
    private String phone;

    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("税号")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "tax")
    private String tax;

    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("邮箱")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "email")
    private String email;

    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("备注")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "remark")
    private String remark;

    @NotNull(message="[状态]不能为空")
    @ApiModelProperty("状态")
    @TableField(value = "status")
    @Dict(dictCode = "sys_normal_disable")
    private Long status;






}

